1. Field of the Invention
This invention relates to transform coding for digital signals, and more particularly to coding of picture signals.
2. Description of the Related Art
Conventionally, a linear transform coding system is known as a coding system for an audio or video signal. In the linear transform coding system, a plurality of discrete signals are linearly transformed collectively and resulting transform coefficients are coded, and compression coding can be achieved by selecting the base of the transform taking statistical characters of the signal into consideration. It is known that a coding system which employs discrete cosine transform for the linear transform can realize high compression coding for a signal which behaves in accordance with a Markovian model, and is utilized widely for international standardized systems.
While the discrete cosine transform is useful for realization of high compression coding, since the base of the transform is a real number, it is disadvantageous in that, in order to realize reversible coding, the quantization step size must be small, which results in deterioration of the coding efficiency.
A system which realizes reversible coding of discrete cosine transform without deterioration of the coding efficiency has been proposed by the inventor of the invention of the present application. The system modifies the discrete cosine transform so as to allow reversible transform. The system has two characteristics: one is to approximate the discrete cosine transform with linear transform with an integer matrix, and the other is to remove redundancies included between transform coefficients by reversible quantization.
In the following, a principle of eight-element reversible cosine transform according to the system described above is described. The original eight-element discrete cosine transform according to the international standards transforms an original signal vector (x0, x1, . . . , x7) into transform coefficients (X0, X1, . . . , X7) in accordance with the following expression (1):                               [                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                X                                                      0                                                                                                                                                                                                                                                                                                                                                                  X                                                      1                                                                                                                                                                                                                                                                                                                                                                                                                                                                              X                                                2                                                                                                                                                                                                                                                                                                                                                                                                                  X                                          3                                                                                                                                                                                                                                                                                                                                                      X                                    4                                                                                                                                                                                                                                                                                          X                              5                                                                                                                                                                                                                              X                        6                                                                                                                                                                  X                  7                                                              ]                =                              [                                                                                c                    4                                                                                        c                    4                                                                                        c                    4                                                                                        c                    4                                                                                        c                    4                                                                                        c                    4                                                                                        c                    4                                                                                        c                    4                                                                                                                    c                    1                                                                                        c                    3                                                                                        c                    5                                                                                        c                    7                                                                                        -                                          c                      7                                                                                                            -                                          c                      5                                                                                                            -                                          c                      3                                                                                                            -                                          c                      1                                                                                                                                        c                    2                                                                                        c                    6                                                                                        -                                          c                      6                                                                                                            -                                          c                      2                                                                                                            -                                          c                      2                                                                                                            -                                          c                      6                                                                                                            c                    6                                                                                        c                    2                                                                                                                    c                    3                                                                                        -                                          c                      7                                                                                                            -                                          c                      1                                                                                                            -                                          c                      5                                                                                                            c                    5                                                                                        c                    1                                                                                        c                    7                                                                                        -                                          c                      3                                                                                                                                        c                    4                                                                                        -                                          c                      4                                                                                                            -                                          c                      4                                                                                                            c                    4                                                                                        c                    4                                                                                        -                                          c                      4                                                                                                            -                                          c                      4                                                                                                            c                    4                                                                                                                    c                    5                                                                                        -                                          c                      1                                                                                                            c                    7                                                                                        c                    3                                                                                        -                                          c                      3                                                                                                            -                                          c                      7                                                                                                            c                    1                                                                                        -                                          c                      5                                                                                                                                        c                    6                                                                                        -                                          c                      2                                                                                                            c                    2                                                                                        -                                          c                      6                                                                                                            -                                          c                      6                                                                                                            c                    2                                                                                        -                                          c                      2                                                                                                            c                    6                                                                                                                    c                    7                                                                                        -                                          c                      5                                                                                                            c                    3                                                                                        -                                          c                      1                                                                                                            c                    1                                                                                        -                                          c                      3                                                                                                            c                    5                                                                                        -                                          c                      7                                                                                            ]                    ⁡                      [                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              x                                                        0                                                                                                                                                                                                                                                                                                                                                                                x                                                        1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  x                                                  2                                                                                                                                                                                                                                                                                                                                                                                                                                      x                                            3                                                                                                                                                                                                                                                                                                                                                                          x                                      4                                                                                                                                                                                                                                                                                                              x                                5                                                                                                                                                                                                                                                  x                          6                                                                                                                                                                                      x                    7                                                                        ]                                              (        1        )            
where c1, . . . , c7 are represented by the following expression (2)                               c          k                =                  cos          ⁡                      (                                          k                ⁢                                  xe2x80x83                                ⁢                π                            16                        )                                              (        2        )            
In this eight-element reversible discrete cosine transform, the eight-element discrete cosine transform represented by the expression (1) is approximated with a transform of the following expression (3):                               [                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                X                                                      0                                                                                                                                                                                                                                                                                                                                                                  X                                                      1                                                                                                                                                                                                                                                                                                                                                                                                                                                                              X                                                2                                                                                                                                                                                                                                                                                                                                                                                                                  X                                          3                                                                                                                                                                                                                                                                                                                                                      X                                    4                                                                                                                                                                                                                                                                                          X                              5                                                                                                                                                                                                                              X                        6                                                                                                                                                                  X                  7                                                              ]                =                              [                                                                                a                    4                                                                                        a                    4                                                                                        a                    4                                                                                        a                    4                                                                                        a                    4                                                                                        a                    4                                                                                        a                    4                                                                                        a                    4                                                                                                                    a                    1                                                                                        a                    3                                                                                        a                    5                                                                                        a                    7                                                                                        -                                          a                      7                                                                                                            -                                          a                      5                                                                                                            -                                          a                      3                                                                                                            -                                          a                      1                                                                                                                                        a                    2                                                                                        a                    6                                                                                        -                                          a                      6                                                                                                            -                                          a                      2                                                                                                            -                                          a                      2                                                                                                            -                                          a                      6                                                                                                            a                    6                                                                                        a                    2                                                                                                                    a                    3                                                                                        -                                          a                      7                                                                                                            -                                          a                      1                                                                                                            -                                          a                      5                                                                                                            a                    5                                                                                        a                    1                                                                                        a                    7                                                                                        -                                          a                      3                                                                                                                                        a                    4                                                                                        -                                          a                      4                                                                                                            -                                          a                      4                                                                                                            a                    4                                                                                        a                    4                                                                                        -                                          a                      4                                                                                                            -                                          a                      4                                                                                                            a                    4                                                                                                                    a                    5                                                                                        -                                          a                      1                                                                                                            a                    7                                                                                        a                    3                                                                                        -                                          a                      3                                                                                                            -                                          a                      7                                                                                                            a                    1                                                                                        -                                          a                      5                                                                                                                                        a                    6                                                                                        -                                          a                      2                                                                                                            a                    2                                                                                        -                                          a                      6                                                                                                            -                                          a                      6                                                                                                            a                    2                                                                                        -                                          a                      2                                                                                                            a                    6                                                                                                                    a                    7                                                                                        -                                          a                      5                                                                                                            a                    3                                                                                        -                                          a                      1                                                                                                            a                    1                                                                                        -                                          a                      3                                                                                                            a                    5                                                                                        -                                          a                      7                                                                                            ]                    ⁡                      [                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              x                                                        0                                                                                                                                                                                                                                                                                                                                                                                x                                                        1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  x                                                  2                                                                                                                                                                                                                                                                                                                                                                                                                                      x                                            3                                                                                                                                                                                                                                                                                                                                                                          x                                      4                                                                                                                                                                                                                                                                                                              x                                5                                                                                                                                                                                                                                                  x                          6                                                                                                                                                                                      x                    7                                                                        ]                                              (        3        )            
where a1, . . . , a7 are natural numbers. The values a1, . . . a7 are obtained by multiplying each row vector of the discrete cosine transform by a certain number and rounding the products into integers. (X0, . . . , X7) obtained based on the expression (3) have values near to the original discrete cosine transform coefficients except that they are multiplied by the certain number.
However, the transform coefficients X0, . . . , X7 obtained based on the expression (3) are not independent of each other, but have redundancies. Where the absolute value of the determinant of a transform matrix is represented by D, the density of points which may be taken in the transform domain is 1/D. In other words, the ratio of the points which may be taken in the transform region from among all integer lattice points is 1/D, and the remaining points of the ratio 1-1/D are wasteful points which cannot be taken actually. To use those wasteful points also as an object for coding makes a cause of decreasing the efficiency of compression coding.
Thus, in order to remove the redundancies, reversible coding is performed. However, since it is difficult to define a reversible transform directly in an eight-element space, the expression (3) is decomposed in accordance with a fast calculation scheme and reversible quantization is performed for results of the individual partial transforms.
The transform of the expression (3) can be decomposed into the following expressions (4) to (10):                               [                                                                                          x                    0                                    +                                      x                    7                                                                                                                                            x                    0                                    -                                      x                    7                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                x                    0                                                                                                                    x                    7                                                                        ]                                              (        4        )                                          [                                                                                          x                    1                                    +                                      x                    6                                                                                                                                            x                    1                                    -                                      x                    6                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                x                    1                                                                                                                    x                    6                                                                        ]                                              (        5        )                                          [                                                                                          x                    2                                    +                                      x                    5                                                                                                                                            x                    2                                    -                                      x                    5                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                x                    2                                                                                                                    x                    5                                                                        ]                                              (        6        )                                          [                                                                                          x                    3                                    +                                      x                    4                                                                                                                                            x                    3                                    -                                      x                    4                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                x                    3                                                                                                                    x                    4                                                                        ]                                              (        7        )                                          [                                                                                          x                    0                                    +                                      x                    7                                    +                                      x                    3                                    +                                      x                    4                                                                                                                                            x                    0                                    +                                      x                    7                                    -                                      x                    3                                    -                                      x                    4                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                                      x                      0                                        +                                          x                      7                                                                                                                                                              x                      4                                        +                                          x                      3                                                                                            ]                                              (        8        )                                          [                                                                                          x                    1                                    +                                      x                    6                                    +                                      x                    2                                    +                                      x                    5                                                                                                                                            x                    1                                    +                                      x                    6                                    -                                      x                    2                                    -                                      x                    5                                                                                ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                                      x                      1                                        +                                          x                      6                                                                                                                                                              x                      2                                        +                                          x                      5                                                                                            ]                                              (        9        )                                          [                                                                      X                  0                                                                                                      X                  4                                                              ]                =                              [                                                            1                                                  1                                                                              1                                                                      -                    1                                                                        ]                    ⁡                      [                                                                                                      x                      0                                        +                                          x                      7                                        +                                          x                      3                                        +                                          x                      4                                                                                                                                                              x                      1                                        +                                          x                      6                                        +                                          x                      2                                        +                                          x                      5                                                                                            ]                                              (        10        )                                          [                                                                      X                  2                                                                                                      X                  6                                                              ]                =                              [                                                                                a                    2                                                                                        a                    6                                                                                                                    a                    6                                                                                        -                                          a                      2                                                                                            ]                    ⁡                      [                                                                                                      x                      0                                        +                                          x                      7                                        -                                          x                      3                                        -                                          x                      4                                                                                                                                                              x                      1                                        +                                          x                      6                                        -                                          x                      2                                        -                                          x                      5                                                                                            ]                                              (        11        )                                          [                                                                                                                                                                                                                            X                              1                                                                                                                                                                                          X                              7                                                                                                                                                                                                                              X                        3                                                                                                                                                                  X                  5                                                              ]                =                              [                                                                                a                    1                                                                                        a                    7                                                                                        a                    3                                                                                        a                    5                                                                                                                    a                    7                                                                                        -                                          a                      1                                                                                                            -                                          a                      5                                                                                                            a                    3                                                                                                                    a                    3                                                                                        -                                          a                      5                                                                                                            -                                          a                      7                                                                                                            -                                          a                      1                                                                                                                                        a                    5                                                                                        a                    3                                                                                        -                                          a                      1                                                                                                            a                    7                                                                        ]                    ⁡                      [                                                                                                                                                                                                                                                                                    x                                  0                                                                -                                                                  x                                  7                                                                                                                                                                                                                                                                          x                                  3                                                                -                                                                  x                                  4                                                                                                                                                                                                                                                                                                              x                            1                                                    -                                                      x                            6                                                                                                                                                                                                                                      x                      2                                        -                                          x                      5                                                                                            ]                                              (        12        )            
It is to be noted that, in the expression (10), a4=1. This is because the matrix of the expression (10) only includes a4 and there is no problem if it is assumed that a4=1. In this manner, the expression (3) can be decomposed into eight 2xc3x972 matrix transforms and one 4xc3x974 matrix transform. Redundancies are produced in the individual transforms. For example, in the transform of the expression (4), since the absolute value of the determinant of the transform matrix is 2, integer vector values which may possibly be taken as a transform results are xc2xd the entire integer vector values. The redundancies produced in the individual transforms in this manner are removed for the individual transforms. To this end, for each transform, a result of the transform is reversibly transformed as seen in FIG. 22. Referring to FIG. 22, reference numerals 160 to 167 denote each a transformer for a 2xc3x972 matrix, and 168 denotes a transformer for a 4xc3x974 matrix.
Here, comparison between an eight-element reversible discrete cosine transform and the original discrete cosine transform is described. Similarly as in FIG. 22, also the original eight-element discrete cosine transform can be decomposed as seen in FIG. 24. In FIG. 24, transform matrices of individual 2xc3x972 and 4xc3x974 transforms are normalized so that they may correspond to those in FIG. 22. From comparison between FIGS. 22 and 24, it can be seen that the transformer 160 and a transformer 180, the transformer 161 and a transformer 181, the transformer 162 and a transformer 182, the transformer 163 and a transformer 183, the transformer 164 and a transformer 184, the transformer 165 and a transformer 185, the transformer 166 and a transformer 186, the transformer 167 and a transformer 187, and the transformer 168 and a transformer 188 correspond to each other. If results obtained by the corresponding transforms are equal, then also transform coefficients obtained finally have substantially equal values. As hereinafter described, this is important when the compatibility between an eight-element reversible discrete cosine transform and the original eight-element discrete cosine transform is considered. It is to be noted that, as can be seen from the comparison between the transforms, the portion of the discrete cosine transform which corresponds to normalization of the base is replaced by reversible quantization in the reversible discrete cosine transform. Consequently, it is important how to make a result of reversible quantization approach a result of normalization in order to achieve the compatibility. Subsequently, the reversible quantization is described in regard to a case of transform by a 2xc3x972 matrix and another case of transform by a 4xc3x974 matrix.
In a transform by a 2xc3x972 matrix, transform points obtained by transforming integer lattice points are reversibly quantized making use of the periodicity of the structure of them. Where the absolute value of the determinant of a transform matrix is represented by D and the coordinates of a transform point obtained by transforming an integer vector are represented by (Y1, Y2), it can be proved that the structure of all of such transform points (Y1, Y2) has the period D in the direction of each axis. Therefore, a region represented by the following expression (13)
{(Y1, Y2)|0xe2x89xa6Y1xe2x89xa6N1xe2x88x921,0xe2x89xa6Y2N2xe2x88x921}xe2x80x83xe2x80x83(13)
(where N1 and N2 are multiples of D, and they are each hereinafter referred to as quantization period) is determined as a basic region, and quantization values of transform points included in the basic region are artificially defined in advance. Then, the correspondence between the transform points and the quantization values is described in the form of and held as a table (this table is hereinafter referred to as quantization correspondence table), and quantization is performed using this table as described below.
An actual procedure of quantization is such as follows. First, quotients b1, b2 and remainders r1, r2 when the coordinates Y1, Y2 of the transform points are divided by the quantization periods N1, N2, respectively. Thus, the remainders (r1, r2) are included in the basic region provided by the expression (13). Then, using the quantization correspondence table defined as above, quantization values (q1, q2) (hereinafter referred to as local quantization) of (r1, r2) are calculated. Then, quantization values (Yq1, Yq2) of (Y1, Y2) are calculated from the quotients b1, b2 and the local quantization values q1, q2 in accordance with the following expressions (14):                     {                                                                              Y                  q1                                =                                                                            b                      1                                        ⁢                                          M                      1                                                        +                                      q                    1                                                                                                                                            Y                  q2                                =                                                                            b                      2                                        ⁢                                          M                      2                                                        +                                      q                    2                                                                                                          (        14        )            
where M1, M2 are natural numbers and represent dynamic ranges of q1, q2, respectively. The values M1 and M2 represent the magnitudes of the basic region when measured with a scale of the quantization values.
The dynamic ranges M1, M2 represent the periods of dequantization described below (therefore, M1, M2 are hereinafter referred to as dequantization periods) Now, dequantization of a 2xc3x972 matrix transform is described. Also dequantization can be performed in a procedure similar to that for quantization. First, quantization values Yq1, Yq2 are divided by the dequantization periods M1, M2 described above to obtain quotients b1xe2x80x2, b2xe2x80x2 and remainders q1xe2x80x2 and q2xe2x80x2, respectively. Then, a table (hereinafter referred to as dequantization correspondence table) which describes a correspondence relationship reverse to that of the quantization correspondence table is referred to obtain (r1xe2x80x2, r2xe2x80x2) corresponding to (q1xe2x80x2, q2xe2x80x2). Then, dequantization values (Y1, Y2) are calculated in accordance with the following expression (15):
                    {                                                                              Y                  1                                =                                                                            b                      1                      xe2x80x2                                        ⁢                                          N                      1                                                        +                                      r                    1                    xe2x80x2                                                                                                                                            Y                  2                                =                                                                            b                      2                      xe2x80x2                                        ⁢                                          N                      2                                                        +                                      r                    2                    xe2x80x2                                                                                                          (        15        )            
Quantization and dequantization of a 2xc3x972 matrix transform are such as described above.
(X1, X7, X3, X5) obtained by transform of a 4xc3x974 matrix given by the following expression (16) are divided into (X1, X7) and (X3, X5), for which quantization is performed separately.                               [                                                                                                                                                                                                                            X                              1                                                                                                                                                                                          X                              7                                                                                                                                                                                                                              X                        3                                                                                                                                                                  X                  5                                                              ]                =                              [                                                                                a                    1                                                                                        a                    7                                                                                        a                    3                                                                                        a                    5                                                                                                                    a                    7                                                                                        -                                          a                      1                                                                                                            -                                          a                      5                                                                                                            a                    3                                                                                                                    a                    3                                                                                        -                                          a                      5                                                                                                            -                                          a                      7                                                                                                            -                                          a                      1                                                                                                                                        a                    5                                                                                        a                    3                                                                                        -                                          a                      1                                                                                                            a                    7                                                                        ]                    ⁡                      [                                                                                                                                                                                                                                                  u                                4                                                                                                                                                                                                        u                                5                                                                                                                                                                                                                                                  u                          6                                                                                                                                                                                      u                    7                                                                        ]                                              (        16        )            
where (u4, u5, u6, u7) are an integer vector. A construction of the conventional 4xc3x974 reversible transformer which realizes a transform of the expression (16) and such 4xc3x974 reversible dequantization is shown in FIG. 26.
The transform coefficients (X1, X7) are linearly quantized with the step sizes k1, k7 (k1 and k7 are natural numbers) by linear quantizers 4, 5, respectively. The values of the quantization step sizes k1, k7 are set so that the dynamic ranges of quantization values (Xq1, Xq7) of (X1, X7) and quantization values (Xq3, Xq5) of (X3, X5) may be nearly equal to each other.
On the other hand, for quantization of the transform coefficients (X3, X5), the relationship described below is utilized. In particular, the relationship that, once (X1, X7) are determined, a certain integer vector (s3, s5) is determined and the values which may possibly be taken by (X3, X5) are limited to the following expression (17) is utilized:                               [                                                                      X                  3                                                                                                      X                  5                                                              ]                =                                            [                                                                    h                                                                              -                      g                                                                                                            g                                                        h                                                              ]                        ⁡                          [                                                                                          n                      1                                                                                                                                  n                      2                                                                                  ]                                +                      [                                                                                s                    3                                                                                                                    s                    5                                                                        ]                                              (        17        )            
where g, h are integers represented, from a1, a3, a5 and a7 of the expression (16), as                     {                                                            g                =                                                      a                    1                    2                                    -                                      a                    7                    2                                    +                                      2                    ⁢                                          a                      3                                        ⁢                                          a                      5                                                                                                                                              h                =                                                      a                    3                    2                                    -                                      a                    5                    2                                    +                                      2                    ⁢                                          a                      1                                        ⁢                                          a                      7                                                                                                                              (        18        )            
Points which may possibly be taken by transform coefficients (X3, X5) represented by the expression (17) are shown in FIG. 28. In this manner, the structure of all of the values which may possibly be taken by the transform coefficients (X3, X5) when certain (X1, X7) are determined is equivalent to a lattice structure defined by vectors (h, g), (xe2x88x92g, h) which is displaced by the integer vector (s3, s5) (hereinafter referred to as representative elements).
Further, when the transform coefficients X1, X7 are linearly quantized with the step sizes k1, k7 as described above, respectively, the structure of values which may be taken by (X3, X5) is a structure wherein k1k7 such lattices as shown in FIG. 28 overlap with each other. This is because the number of transform coefficients (X1, X7) which may be rounded to one quantization values (Xq1, Xq7) is k1k7, and representative elements (s3, s5) correspond to each of the k1k7 transform coefficients. Since only the portion of the representative elements (s3, s5) in the expression (17) varies depending upon the values of (X1, X7), the set of all of points which may be taken by the transform coefficients (X3, X5) when X1, X7 are linearly quantized with the step sizes k1, k7, respectively, is equivalent to the lattice structure of the expression (17) which overlaps at the k1k7 transform coefficients but is different only in a manner of displacement. For example, when k1=k7=2, points which may be taken by the transform coefficients (X3, X5) are such as illustrated in FIG. 29. As can be seen from FIG. 29, the structure of points which may possibly be taken by the transform coefficients (X3, X5) exhibits a repetition of the same pattern for each period defined by the vectors (h, g), (xe2x88x92g, h). Therefore, the points are divided into groups each of which includes points whose global signal values (p3, p5) are equal to each other, and quantization is performed for each of the groups. Then, in each group, the global signal (p3, p5) which has an equal value in the group and representative elements (s3, s5) which are different for individual points in the group are quantized separately, and then resulting quantized values are added to calculate a quantized value. Subsequently, description is given of the quantization.
First, a procedure of calculating quantization values (pq3, pq5) of global signals (p3, p5) is described. The structure of all of points which may possibly be taken by the global signals (p3, p5) includes transform points obtained by transforming, from the expression (17), integer lattice points with the matrix                     [                                            h                                                      -                g                                                                        g                                      h                                      ]                            (        19        )            
Therefore, for the global signals (p3, p5), reversible quantization performed in the 2xc3x972 matrix transform described above is performed. First, in order to obtain the global signals (p3, p5), representative elements (s3, s5) are determined from values of transform coefficients X1, X7 based on a first numeric table 201. Details are hereinafter described. Next, s3, s5 are subtracted from X3, X5 to obtain global signals p3, p5 by adders 14, 15, respectively. Then, the aforementioned 2xc3x972 reversible quantization based on the matrix of the expression (19) is performed by a transformer 202. Results of the 2xc3x972 revisable quantization are multiplied by m3, m5 by multipliers 204 and 205 to calculate global quantization values (pq3, pq5). Here, m3, m5 represent dynamic ranges of the local quantization values sq3, sq5, respectively.
Subsequently, a procedure of calculating the quantization values (sq3, sq5) of the representative elements (s3, s5) is described. This does not directly calculate the quantization values from values of the representative elements (s3, s5), but determines the quantization values using a second numeric table 203 from quantization residuals (r1, r7) of the transform coefficients (X1, X7) represented by the following expression (20):                     {                                                                              r                  1                                =                                                      X                    1                                    -                                                            k                      1                                        ⁢                                          X                      q1                                                                                                                                                                r                  7                                =                                                      X                    7                                    -                                                            k                      7                                        ⁢                                          X                      q7                                                                                                                              (        20        )            
Then, adders 16 and 17 add the local quantization values sq3, sq5 to the global quantization values pq3, pq5 to obtain quantization values (Xq3, Xq5), respectively. By the processing described above, all quantization values (Xq1, Xq7, Xq3, Xq5) are obtained.
Subsequently, a procedure of calculating the representative elements (s3, s5) from the values of the transform coefficients (X1, X7) based on the first numeric table 201 of FIG. 26 is described. The values of the representative elements (s3, s5) vary depending upon the values of the transform coefficients (X1, X7). However, where the values of g, h are given by the expression (18), if the remainders when components of the vector (gX1+hX7, gX7xe2x88x92hX1) are divided by the determinant of the matrix of the expression (19)
D4=g2+h2xe2x80x83xe2x80x83(21)
are equal to each other, then also the representative elements (s3, s5) are equal. In other words, where the remainder when x is divided by y is represented by mod(x, y), the representative elements (s3, s5) vary depending upon the value of the vector
Z(X1, X7)=(mod(gX1+hX7,D4),mod(gX7xe2x88x92hX1,D4))xe2x80x83xe2x80x83(22)
Thus, in the first numeric table, the correspondence relationship between the vector z(X1, X7) and the representative elements (s3, s5) is described. Then, the value of the vector z(X1, X7) of the expression (22) is calculated first, and then referring to the first numeric table 201 of FIG. 26, the representative elements (s3, s5) are determined from the value of the vector z(X1, X7). Particularly if g and h are prime relative to each other, then if one of two components                     {                                                                                                  z                    1                                    ⁡                                      (                                                                  X                        1                                            ,                                              X                        7                                                              )                                                  =                                  mod                  ⁡                                      (                                                                                            gX                          1                                                +                                                  hX                          7                                                                    ,                                              D                        4                                                              )                                                                                                                                                                z                    2                                    ⁡                                      (                                                                  X                        1                                            ,                                              X                        7                                                              )                                                  =                                  mod                  ⁡                                      (                                                                                            gX                          7                                                -                                                  hX                          1                                                                    ,                                              D                        4                                                              )                                                                                                          (        23        )            
of the vector z(X1, X7) is determined, then the representative elements (s3, s5) can be determined without determining the other components. Accordingly, in this instance, (s3, s5) can be determined by describing the corresponding relationship between one of two components of each of z1(X1, X7), z1(X1, X7) of the expression (23) and the representative elements (s3, s5) in the first numeric table.
Subsequently, a procedure of calculating the local quantization values (sq3, sq5) from the quantization residuals (r1, r7) based on the second numeric table 203 is described. First, local quantization of the transform coefficients (X3, X5) is described, and then a procedure of calculating (s3, s5) using the quantization residuals (r1, r7) is described.
As described above, when the transform coefficients X1, X7 are linearly quantized with the step sizes k1, k7, a resulting structure includes such k1k7 overlapping lattice point structures as represented by the expression (17) as seen in FIG. 29. Local quantization of the transform coefficients (X3, X5) groups k1k7 points whose global signals (p3, p5) are same into a group and allocates different quantization values (sq3, sq5) to representative elements of the k1k7 points. Quantization from the representative elements (s3, s5) into the local quantization values (sq3, sq5) can be realized by referring to a table prepared so as to describe the correspondence between them. However, since the set of values which may possibly be taken by the representative elements (s3, s5) depends upon the values of (Xq1, Xq7), a plurality of tables each describing such a correspondence are required. However, if the values of the representative elements (s3, s5) for the quantization representative values (X1, X7)=(k1Xq1, k7Xq7) are equal, then also the values of the representative elements (s3, s5) for the other (k1k7xe2x88x921) different (X1, X7) in the same group coincide with them. Consequently, in this instance, a same correspondence table can be used. Accordingly, the number of those correspondence tables which must be prepared is a number equal to the number of values which may possibly be taken by (s3, s5). This value is equal to or smaller than D4. Then, a table is selected based on the representative elements (s3, s5) for the quantization representative values (k1Xq1, k7Xq7) and used for quantization.
Here, for such selection of a table, in place of the values of the representative elements (s3, s5) for the quantization representative values (k1Xq1, k7Xq7), the values of the expression (22) for the quantization representative values, that is, the values of the vector z(k1X1, k7X7) may be used. In other words, a table can be selected using the values of the vector z(k1X1, k7X7) as an index. By this, a table can be selected directly without calculating the values of the representative values for the quantization representative values using the first numeric table. It is to be noted that, if g and h are prime relative to each other, then only one of components z1(k1X1, k7X7) and z2(k1X1, k7X7) of the vector z(k1X1, k7X7) may be used as an index.
Further, in order to calculate the local quantization values (sq3, sq5), the quantization residuals (r1, r7) represented by the expression (20) may be used in place of the quantization representative values (s3, s5). This is because, if (Xq1, Xq7) is determined, then also the correspondence between (X1, X7) and (r1, r7) is determined. Since the set of values which may possibly be taken by the representative values (s3, s5) is different depending upon the quantization values (Xq1, Xq7), where the local quantization values (sq3, sq5) are determined directly from the representative elements (s3, s5), also the values of the representative values (s3, s5) must necessarily be written in the table. In contrast, since the set of values which may possibly be taken by the quantization residuals (r1, r7) does not depend upon the quantization values (Xq1, Xq7), this information need not be held. Therefore, the table may have a reduced size.
Subsequently, dequantization of a 4xc3x974 matrix transform is described. First, a construction of a 4xc3x974 inverse transformer of the system proposed by the inventor of the inventor of the present application is shown in FIG. 27. Referring to FIG. 27, in the 4xc3x974 inverse transformer, quantization values (Xq1, Xq7, Xq3, Xq5) are dequantized to obtain (X1, X7, X3, X5), and then the dequantization values (X1, X7, X3, X5) are inverse transformed as given by the following expression (24) inverse to the expression (16) to obtain an integer vector (u4, u5, u6, u7).                               [                                                                      u                  4                                                                                                      u                  5                                                                                                      u                  6                                                                                                      u                  7                                                              ]                =                                            [                                                                                          a                      1                                                                                                  a                      7                                                                                                  a                      3                                                                                                  a                      5                                                                                                                                  a                      7                                                                                                  -                                              a                        1                                                                                                                        -                                              a                        5                                                                                                                        a                      3                                                                                                                                  a                      3                                                                                                  -                                              a                        5                                                                                                                        -                                              a                        7                                                                                                                        -                                              a                        1                                                                                                                                                        a                      5                                                                                                  a                      3                                                                                                  -                                              a                        1                                                                                                                        a                      7                                                                                  ]                                      -              1                                ⁡                      [                                                                                X                    1                                                                                                                    X                    7                                                                                                                    X                    3                                                                                                                    X                    5                                                                        ]                                              (        24        )            
Subsequently, the dequantization from the quantization values (Xq1, Xq7, Xq3, Xq5) to the transform coefficients (X1, X7, X3, X5) is described. Also this is performed separately for (Xq1, Xq7) and (Xq3, Xq5).
The quantization values (Xq1, Xq7) are first multiplied by k1, k7 by multipliers 34, 35 to obtain quantization representative values (k1Xq1, k7Xq7), respectively. Then, quantization residuals (r1, r7) are added to the quantization representative values (k1Xq1, k7Xq7) by adders 36, 37 to calculate (X1, X7), respectively. The quantization residuals (r1, r7) are calculated from local quantization values (sq3, sq5) calculated by a procedure which will be hereinafter described using a third numeric table 211. The third numeric table 211 is a table which describes correspondences reverse to those of the second numeric table of FIG. 26. Then, similarly as in the reversible transformer of FIG. 26, when the third numeric table 211 is to be referred to, the values of the vector z(X1, X7) of the expression (22) for the quantization representative values (k1Xq1, k7Xq7), that is, the values of the vector z(k1Xq1, k7Xq7), are used as an index. It is to be noted that, also in this instance, if g and h are prime relative to each other, then only one of two components z1(k1Xq1, k7Xq7) and z2(k1Xq1, k7Xq7) of the vector z(k1Xq1, k7Xq7) may be used as an index.
Meanwhile, the quantization values Xq3, Xq5 are first divided by m3, m5 by integer dividers 212, 213 to obtain quotients pq3, pq5 and remainders sq3, sq5, respectively once the local quantization values (sq3, sq5) are calculated, transform coefficients (X1, X7) can be calculated as described above. Then, a dequantizer 210 dequantizes the quotients (pq3, pq5) based on the matrix of the expression (19) to obtain global signals (p3, p5). Then, from the transform coefficients (X1, X7) calculated already, representative elements (s3, s5) are determined using a fourth numeric table 214 equivalent to the first numeric table 201 of FIG. 26. Adders 38, 39 add the global signals (p3, p5) to the representative elements (s3, s5) to obtain transform coefficients (X3, X5), respectively. By the procedure described above, dequantization is completed and the transform coefficients (X1, X7, X3, X5) are obtained. Quantization and dequantization of a 4xc3x974 matrix transform are such as described above.
By performing reversible quantization of a 2xc3x972 or 4xc3x974 matrix transform described above after each transform of the expressions (4) to (12) as seen in FIG. 22, redundancies included in results of transform can be removed. As a result, reversible coding can be realized without deteriorating the coding efficiency. Further, by suitably adjusting the quantization period N1 and the dequantization period M1, transform coefficients of eight-element reversible discrete cosine transform obtained finally can be made to approach those of the original discrete cosine transform.
One of problems of the conventional eight-element reversible discrete cosine transform described above resides in that it is not sufficiently compatible with the original eight-element discrete cosine transform. In particular, the quality of a reproduction signal obtained when a signal coded using eight-element reversible discrete cosine transform is decoded using the original eight-element inverse discrete cosine transform or when reverse decoding is performed is not sufficiently high.
The reason is that the differences (hereinafter referred to as errors) between transform coefficients of the conventional eight-element reversible discrete cosine transform and transform coefficients of the original eight-element discrete cosine transform are not small. This arises from the fact that the differences between Xq1, Xq7, Xq3, Xq5 obtained by 4xc3x974 reversible quantization by the transformer 168 of FIG. 22 and X1, X7, X3, X5 obtained by transform by the transformer 188 shown in FIG. 24 are not small. While the errors of the transform coefficients may be caused by three different factors including errors originating from a difference in dynamic range, errors originating from quantization which uses a table and approximate errors caused by integer transform, in the conventional reversible quantization based on a 4xc3x974 matrix transform described above, global quantization of (X3, X5) is performed using a table as described above, and then resulting values are multiplied by m3, m5 as seen from FIG. 26. As a result, quantization errors arising from use of the table are amplified to m3, m5 times, thereby increasing the errors.
It is an object of the present invention to provide a transform coding system wherein transform coefficients of reversible discrete cosine transform are made to approach original discrete cosine transform coefficients to improve the compatibility of the reversible discrete cosine transform with the original discrete cosine transform.
More particularly, the object of the present invention resides in provision of a transform coding system which improves the quality of a reproduction signal obtained when a signal coded using reversible discrete cosine transform is decoded using the original discrete cosine transform.
In order to attain the objects described above, according to a first aspect of the present invention, there is provided a reversible transform coding system which quantizes an original signal using a reversible transformer which effects reversible discrete cosine transform and wherein the reversible transformer reversibly transforms an integer four-element vector (u4, u5, us, u7) of the original signal into quantization values (Xq1, Xq7, Xq3, Xq5), the reversible transformer including means for linearly transforming the integer four-element vector (u4, u5, u6, u7) with the 4xc3x974 integer matrix of the expression (16) to obtain transform coefficients (X1, X7, X3, X5), means for linearly quantizing the transform coefficients X1, X7 with step sizes of natural numbers k1, k7 to obtain quantization values Xq1, Xq7 and quantization residuals r1, r7, respectively, means for determining representative elements (s3, s5) from a first numeric table using the transform coefficients (X1, X7) or the transform coefficients (X3, X5), means for subtracting the representative elements (s3, s5) from the transform coefficients (X3, X5) to calculate global signals (p3, p5), means for linearly quantizing components p3, p5 of the global signals (p3, p5) with step sizes of real numbers L3, L5 to obtain global quantization values pq3, pq5, respectively, means for determining local quantization values (sq3, sq5) from the quantization residuals (r1, r7) based on a second numeric table, and means for adding the local quantization values (sq3, sq5) to the global quantization values (pq3, pq5) to obtain quantization values (Xq3, Xq5) and supplying the quantization values (Xq3, Xq5) as quantization values for the transform coefficients (X3, X5).
In the conventional reversible transform system described hereinabove with reference to FIG. 26, quantization defined by a table is performed by the transformer 202, and quantization errors produced in the quantization are amplified to m3, m5 times by the multipliers 204, 205, respectively. Therefore, there is a tendency that the differences between the values of the transform coefficients Xq3, Xq5 obtained thereby and transform coefficients X3, X5 obtained by the transformer 188 of the original discrete cosine transform shown in FIG. 24 become large. However, with the reversible transform coding system, since global quantization values of transform coefficients X3, X5 are calculated by linear quantization, the values of Xq3, Xq5 obtained are near to the transform coefficients X3, X5 obtained by the transformer 188.
According to a second aspect of the present invention, there is provided a reversible transform coding system which includes a reversible transformer which inversely transforms quantization values (Xq1, Xq7, Xq3, Xq5) into an integer four-element vector (u4, u5, u8, u7), the reversible transformer including means for calculating global signals (p3, p5) and local quantization values (sq3, sq5) from the quantization values (Xq3, Xq5), means for determining quantization residuals (r1, r7) from the local quantization values (sq3, sq5) based on a third numeric table, means for multiplying the quantization values (Xq1, Xq7) by natural numbers k1, k7 and adding the quantization residuals (r1, r7) to the products to obtain transform coefficients (X1, X7), respectively, means for determining representative elements (s3, s5) from the transform coefficients X1, X7 based on a fourth numeric table, means for adding the representative elements (s3, s5) to the global signals (p3, p5) to obtain transform coefficients (X3, X5), and means for linearly transforming the transform coefficients (X1, X7, X3, X5) with an inverse matrix to the 4xc3x974 matrix of the expression (16) to obtain the integer four-element vector (u4, u5, u6, u7). The reversible transform coding system provides inverse transform to the transform of the reversible transform coding system of the first aspect of the present invention. Reversible transform can be achieved by utilizing both of the reversible transform coding systems.
The means for calculating global signals (p3, p5) and local quantization values (sq3, sq5) from the quantization values (Xq3, Xq5) may include means for calculating global signal candidates (p3(xe2x88x85), p5(xe2x88x85))from the quantization values (Xq3, Xq5) based on two dimensional division with the matrix of the expression (19) where g, h are integers which are given, from integers a1, a3, a5, a7, by g=a12xe2x88x92a72+2a3a5, h=a32xe2x88x92a52+2a1a7, respectively, means for adding global signal differences (xcex94p3(1), xcex94p5(1)), (xcex94p3(2), xcex94p5(2)), (xcex94p3(3), xcex94p5(3)) given in advance to the global signal candidates (p3(xe2x88x85), p5(xe2x88x85)) to calculate global signal candidates (p3(1), p5(1)), (p3(2), p5(2)), (p3(3), p5(3)), respectively, means for linearly quantizing the global signal candidates p3(xe2x88x85), p5(xe2x88x85) with step sizes of real numbers L3, L5 to obtain global quantization value candidates pq3(xe2x88x85), pq5(xe2x88x85) and subtracting the global quantization value candidates pq3(xe2x88x85), pq5(xe2x88x85) from the quantization values (Xq3, Xq5) to obtain local quantization value candidates sq3(xe2x88x85), sq5(xe2x88x85), means for linearly quantizing the global signal candidates p3(1), p5(1) with the step sizes of the real numbers L3, L5 to obtain global quantization value candidates pq3(1), pq5(1) and subtracting the global quantization value candidates pq3(1), pq5(1) from the quantization values (Xq3, Xq5) to obtain local quantization value candidates sq3(1), sq5(1), means for linearly quantizing the global signal candidates p3(2), p5(2) with the step sizes of the real numbers L3, L5 to obtain global quantization value candidates pq3(2), pq5(2) and subtracting the global quantization value candidates pq3(2), pq5(2) from the quantization values (Xq3, Xq5) to obtain local quantization value candidates sq3(2), sq5(2), means for linearly quantizing the global signal candidates p3(3), p5(3) with the step sizes of the real numbers L3, L5 to obtain global quantization value candidates pq3(3), pq5(3) and subtracting the global quantization value candidates pq3(3), pq5(3) from the quantization values (Xq3, Xq5) to obtain local quantization value candidates sq3(3), sq5(3), and means for selecting values which may possibly be local quantization values from among the local quantization value candidates (sq3(xe2x88x85), sq5(xe2x88x85)), (sq3(1), sq5(1), (sq3(2), sq5(2), (sq3(3), sq5(3), setting the selected values to the local quantization values (sq3, sq5) and setting the global signal candidates corresponding to the local quantization values (sq3, sq5) to the global signals (p3, p5).
Alternatively, the means for calculating global signals (p3, p5) and local quantization values (sq3, sq5) from the quantization values (Xq3, Xq5) may include means for calculating global signal candidates (p3(xe2x88x85), p5(xe2x88x85) from the quantization values (Xq3, Xq5) based on two dimensional division with the matrix of the expression (19) where g, h are integers which are given, from integers a1, a3, a5, a7, by g=a2xe2x88x92a72+2a3a5, h=a32xe2x88x92a52+2a1a7, respectively, means for linearly quantizing the global signal candidates (p3(xe2x88x85), p5(xe2x88x85)) with step sizes of real numbers L3, L5 to obtain global quantization value candidates (pq3(xe2x88x85), pq5(xe2x88x85) and quantization residuals (r3(xe2x88x85), r5(xe2x88x85)), means for subtracting the global quantization value candidates (pq3(xe2x88x85), pq5(xe2x88x85)) from the quantization values (Xq3, Xq5) to obtain local quantization value candidates (sq3(xe2x88x85), sq5(xe2x88x85)), means for determining an index I from the quantization residuals (r3(xe2x88x85), r5(xe2x88x85), means for determining local quantization values (sq3, sq5) and global difference signals (xcex94p3, xcex94p5) from the local quantization value candidates (sq3(xe2x88x85), sq5(xe2x88x85)) based on a fifth numeric table selected using the index I, and means for adding the global difference signals (xcex94p3, xcex94p5) to the global signal candidates (p3(xe2x88x85), p5(xe2x88x85)) to calculate the global signals (p3, p5). This provides simpler means for calculating the global signals (p3, p5) and the local quantization values (sq3, sq5) from the quantization values (Xq3, Xq5).
The means for calculating global signal candidates (p3(xe2x88x85), p5(xe2x88x85)) from the quantization values (Xq3, Xq5) may include means for multiplying the quantization values Xq3, Xq5 by the real numbers L3, L5 to obtain quantization representative values (Xq3L3, Xq5L5), respectively, means for transforming the quantization representative values (Xq3L3, Xq5L5) with an inverse matrix to the matrix of the expression (19) represented using g, h which are given, from integers a1, a3, a5, a7, by g=a12xe2x88x92a72+2a3a5, h=a32xe2x88x92a52+2a1a7, respectively, to obtain inverse transform points (w3, w5), means for raising fractions of the inverse transform points w3, w5 to unit or discarding fractions of the inverse transform points w3, w5 to convert the inverse transform points w3, w5 into integers w3xe2x80x2, w5xe2x80x2, and means for transforming a vector (w3xe2x80x2, w5xe2x80x2) composed of the integers w3xe2x80x2, w5xe2x80x2 with the matrix of the expression (19) to obtain the global signal candidates (p3(xe2x88x85), p5(xe2x88x85).
According to a third aspect of the present invention, there is provided a reversible transform coding system which quantizes an original signal using a reversible transformer which effects reversible discrete cosine transform and wherein the reversible transformer produces eight transform coefficients of quantization values Xq0, Xq1, Xq2, Xq3, Xq4, Xq5, Xq6, Xq7 from eight signals of x0, x1, x2, x3, x4, x5, x6, x7, the reversible transformer including means for performing transform with a matrix                     [                                            1                                      1                                                          1                                                      -                1                                                    ]                            (        25        )            
for the signals (x0, x7 ), (x1, x6), (x3, x4), (x2, x5) and reversible quantization for the results to obtain quantization values (u0, u4), (u2, u6), (u1, u5), (u3, u7), means for performing transform with the matrix of the expression (25) for the quantization values (u0, u1), (u2, u3) and reversible quantization for the results to obtain quantization values (v0, v1), (v2, v3), means for performing transform with the matrix of the expression (25) for the quantization values (v0, v2) and reversible quantization for the results to obtain quantization values and setting the quantization values as the quantization values (Xq0, Xq4), means for performing transform with an integer matrix given by                     [                                                            a                2                                                                    a                6                                                                                        a                6                                                                    -                                  a                  2                                                                    ]                            (        26        )            
where a2 and a6 are integers for the quantization values (v1, v3) and reversible quantization for the results to obtain quantization values and setting the quantization values as the quantization values (Xq2, Xq6), and means for performing reversible transform performed in the reversible transform coding system of the first aspect of the present invention for the quantization values (u4, u5, u6, u7) to obtain the quantization values (Xq1, Xq7, Xq3, Xq5).
In the reversible transform coding system, transform with a 4xc3x974 matrix of the conventional eight-element reversible discrete cosine transform is replaced with the transform by the reversible transform coding system according to the first aspect of the present invention described above. Consequently, eight-element reversible discrete cosine transform by which values nearer to transform coefficients of the original eight-element discrete cosine transform than those of the conventional system can be achieved. When a signal coded using this eight-element reversible discrete cosine transform is to be decoded, if inverse transform to this transform is used, then the original signal can naturally be reconstructed completely. However, even where the signal is decoded using the conventional eight-element discrete cosine inverse transform, a signal near to the original signal can be obtained. In other words, the compatibility with the conventional discrete cosine transform is improved.
According to a fourth aspect of the present invention, there is provided a reversible transform coding system which includes a reversible transformer which produces eight signals of x0, x1, x2, x3, x4, x5, x6, x7 from eight transform coefficients of quantization values Xq0, Xq1, Xq2, Xq3, Xq4, Xq5, Xq6, Xq7, the reversible transformer including means for performing inverse transform as recited in claim 2 for the quantization values Xq1, Xq7, Xq3, Xq5 to obtain a vector of quantization values (u4, u5, u6, u7), means for performing dequantization based on the matrix of the expression (26) where a2 and a6 are integers for the quantization values (Xq2, Xq6) and transform for the dequantized values with an inverse matrix to the matrix to obtain a vector of quantization values (v1, v3), means for performing dequantization based on the matrix of the expression (25) for the quantization values (Xq0, Xq4) and transform for the dequantized values with an inverse matrix to the matrix to obtain a vector of quantization values (v0, v2), means for performing dequantization based on the matrix of the expression (25) for the quantization values (v0, v1), (v2, v3) and transform for the dequantized values with an inverse matrix to the matrix to obtain vectors of quantization values (u0, u1), (u2, u3), respectively, and means for performing dequantization based on the matrix of the expression (25) for the quantization values (u0, u4), (u2, u6), (u1, u5), (u3, u7) and transform for the dequantized values with an inverse matrix to the matrix to obtain the signals (x0, x7 ), (x1, x6), (x3, x4), (x2, x5), respectively. This provides inverse transform to that of the reversible transform coding system according to the third aspect of the present invention described above. If both of the reversible transform coding systems are employed, an eight-element reversible discrete cosine transform system by which values nearer to transform coefficients of the original eight-element discrete cosine transform than those of the conventional system can be obtained can be constructed.
Preferably, the reversible transform coding system according to the third aspect of the present invention is constructed such that the integers a1, a3, a5, a7 are 5, 4, 3, 1, respectively, and the integers a2, a6 are 12, 5, respectively. Where the specific values are used, values particularly near to transform coefficients of the original eight-element discrete cosine transform can be obtained.
Preferably, the reversible transform coding system according to the fourth aspect of the present invention is constructed such that the integers a1, a3, a5, a7 are 5, 4, 3, 1, respectively, and the integers a2, a6 are 12, 5, respectively. This provides inverse transform to that of the preceding reversible transform coding system.
Preferably, the reversible transform coding system according to the third aspect of the present invention is constructed such that the matrix of the expression (26) is set such that the inters a2, as are 12, 5, respectively, and the reversible quantization is linear quantization with a step size of 13. This eliminates use of a quantization correspondence table in quantization of the means for performing transform.
Preferably, the reversible transform coding system according to the fourth aspect of the present invention is constructed such that the reversible transformer includes, in place of the means for performing dequantization for the quantization values (Xq2, Xq6) based on the matrix of the expression (26) where a2 and a6 are integers and inverse transform with the matrix for the dequantized values to obtain a vector of quantization values (v1, v3), means for multiplying the quantization values (Xq2, Xq6) by 13 to obtain a vector, linearly transforming the vector with an inverse matrix to the matrix given above obtained where the integers a2, a6 are 12, 5, respectively, and rounding results of the linear transform to obtain the quantization values (v1, v3). This provides inverse transform to that of the preceding reversible transform coding system. In this dequantization, no correspondence table is required.
In the reversible transform coding systems described above, transform coefficients to be obtained are allowed to approach transform coefficients of the original discrete cosine transform by suitably adjusting such parameters as a quantization period and a dequantization period. However, there is a limitation to such approaching, and the dynamic ranges of transform coefficients obtained are different a little from the dynamic ranges of transform coefficients of the original discrete cosine transform by all means. Therefore, reversible transform coding systems of the present invention described below are constructed so that the quality of a reconstructed signal obtained when decoding is performed using the original discrete cosine transform is improved.
It is to be noted that the reversible discrete cosine transform employed in the reversible transform coding systems described above can be applied also to reversible discrete cosine transform employed the following reversible transform coding systems, and this application achieves further improvement of the quality of a reconstructed signal.
According to a fifth aspect of the present invention, there is provided a reversible transform coding system for quantizing a picture signal using a reversible transformer which effects reversible discrete cosine transform, comprising means for calculating a difference between a dynamic range of a transform coefficient obtained by the reversible transformer and a dynamic range of a transform coefficient of discrete cosine transform according to the JPEG and storing a JPEG compatibility quantization table with which the difference is small, and means for variable length coding for transform coefficients obtained by the reversible transformer and the values of the JPEG compatibility quantization table into a coded signal and outputting the coded signal.
While a conventional picture coding system which employs reversible discrete cosine transform does not use a quantization table, the reversible transform coding system according to the fifth aspect of the present invention employs a quantization table for compensation for a difference in dynamic range. Consequently, the reversible transform coding system can improve the compatibility with the JPEG (Joint Photographic Coding Experts Group) which is international standards for picture coding based on discrete cosine transform. Further, the reversible transform coding system can be realized simply only by preparing a storage apparatus for storing the fixed quantization table.
According to a sixth aspect of the present invention, there is provided a reversible transform coding system for coding a moving picture signal using a reversible transformer which effects reversible discrete cosine transform, comprising means for performing motion estimation between an already coded picture and a coding object picture to obtain a motion vector, means for performing motion compensation using the motion vector to produce a predicted picture from the already coded picture, means for subtracting the predictive picture from the coding object picture to produce a predictive error picture, means for performing reversible discrete cosine transform for the predictive error picture to calculate transform coefficients, means for calculating a difference between a dynamic range of a transform coefficient obtained by the reversible transformer and a dynamic range of a transform coefficient of discrete cosine transform according to the MPEG and storing an MPEG compatibility quantization matrix with which the difference is small, and means for variable length coding for the transform coefficients, the MPEG compatibility quantization matrix and the motion vector into a coded signal and outputting the coded signal.
Similarly to the reversible transform coding system according to the fifth aspect of the present invention, the reversible transform coding system according to the sixth aspect employs a quantization matrix for compensation for a difference in dynamic range, and consequently, it can improve the compatibility with the MPEG which is international standards for picture coding based on discrete cosine transform. Further, the reversible transform coding system can be realized simply only by preparing a storage apparatus for storing the fixed quantization matrix values.
According to a seventh aspect of the present invention, there is provided a reversible transform coding system for quantizing a picture signal using a reversible transformer which effects reversible discrete cosine transform, comprising means for performing discrete cosine transform for the picture signal to obtain discrete cosine transform coefficients, JPEG compatibility quantization table production means for calculating elements of the table with which differences between of transform coefficients obtained by the reversible transformer and the discrete cosine transform coefficients are small to produce a JPEG compatibility quantization table, and means for variable length coding for transform coefficients calculated by the reversible transformer and the values of the JPEG compatibility quantization table into a coded signal and outputting the coded signal.
With the reversible transform coding system, since values of the quantization table for compensation for a difference between the transform coefficients of reversible transformer and the discrete cosine transform coefficient are sequentially calculated, the compatibility with the JPEG can be improved adaptively compared with an alternative system which employs a fixed quantization table.
According to an eighth aspect of the present invention, there is provided a reversible transform coding system for coding a moving picture signal, comprising means for performing motion estimation between an already coded picture and a coding object picture to obtain a motion vector, means for performing motion compensation using the motion vector to produce a first predictive picture from the already coded picture, means for subtracting the first predictive picture from the coded object picture to produce a first predictive error picture, means for performing reversible discrete cosine transform for the first predictive error picture to calculate reversible discrete cosine transform coefficients, means for subtracting a second predictive picture from the coding object picture to produce a second predictive error picture, means for performing discrete cosine transform for the second predictive error signal to calculate discrete cosine transform coefficients, MPEG compatibility quantization matrix production means for calculating elements of the matrix with which differences between the reversible discrete cosine transform coefficients and the discrete cosine transform coefficients are small to produce an MPEG compatibility quantization matrix and outputting a dequantized reversible discrete cosine transform coefficient when the MPEG compatibility quantization matrix is used, means for performing inverse discrete cosine transform for the dequantization values to calculate a predictive error reproduction picture, means for adding the second predictive picture to the predictive error reproduction picture to produce a reproduction picture, and means for performing motion compensation using the motion vector to produce the second predictive picture from the reproduction picture.
Also with the present reversible transform coding system, the compatibility with the MPEG can be improved adaptively compared with an alternative system which employs a fixed quantization matrix.
Preferably, the reversible transform coding system according to the seventh or eight aspect of the present invention is constructed such that, in order to decrease the amount of calculation processing in quantization and dequantization of transform coefficients, the JPEG compatibility quantization table production means or the MPEG compatibility quantization matrix production means includes means for calculating, from transform coefficients Xq(i, j) of the reversible discrete cosine transform, values Xxe2x80x2(i, j) corresponding to results when values of the transform coefficients Xq(i, j) prior to conversion into integers in dequantization are divided by the values of the quantization table or matrix, means for adding or subtracting a very small value to or from transform coefficients XT(i, j) of the discrete cosine transform in accordance with values of the conversion coefficients Xq(i, J) of the reversible discrete cosine transform to obtain values Xxe2x80x2T(i, j), means for producing a quantization table or matrix by calculation based on secondary moments regarding the values Xxe2x80x2(i, j) and the values Xxe2x80x2T(i, j), and means for dequantizing the transform coefficients of the reversible discrete cosine transform using the quantization table or matrix and outputting resulting dequantization values.
Preferably, the reversible transform coding system according to the ninth aspect of the present invention is constructed such that, in order to further improve the quality of a decoded picture, it further comprises, in addition to the JPEG compatibility quantization table production means or the MPEG compatibility quantization matrix production means, means for dequantizing the transform coefficients of the reversible discrete cosine transform with the values of the JPEG compatibility quantization table or the MPEG compatibility quantization matrix to obtain dequantization values, means for calculating, for each of the transform coefficients of the discrete cosine transform, a square mean of differences between the transform coefficient and the dequantization values, and means for correcting the values of the JPEG compatibility quantization table or the MPEG compatibility quantization matrix based on the square means and outputting the corrected JPEG compatibility quantization table or the MPEG compatibility quantization matrix.
Preferably, the reversible transform coding system according to the tenth aspect of the present invention is constructed such that means for performing reversible discrete cosine transform to calculate reversible discrete cosine transform coefficients performs eight-element reversible discrete cosine transform in a vertical direction and a horizontal direction for two-dimensional signals of an 8xc3x978 block, and uses different quantization correspondence tables between any three stages and the remaining three stages out of six stages of reversible quantization based on a 2xc3x972 matrix represented using 1, xe2x88x921 which is performed when a DC component is to be calculated, to cancel the difference between in dynamic ranges DC component of the reversible discrete cosine transform and that of original discrete cosine transform.
The above and other objects, features and advantages of the present invention will become apparent from the following description and the appended claims, taken in conjunction with the accompanying drawings in which like parts or elements are denoted by like reference characters.